package com.chk.user.controller.sys;


import com.chk.commom.utils.CommonResult;
import com.chk.user.service.UserService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.web.bind.annotation.GetMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RequestParam;
import org.springframework.web.bind.annotation.RestController;

@RestController
@RequestMapping("/sys/user")
public class SysUserController {
    @Autowired
    private UserService userService;
    @GetMapping("/list")
    public CommonResult getUserList(@RequestParam(value = "condition",required = false) String condition,
                                    @RequestParam(value = "pageNow",defaultValue = "1") Integer pageNow,
                                    @RequestParam(value = "pageSize",defaultValue = "10")Integer pageSize){
        return userService.getUserList(condition,pageNow,pageSize);
    }
}
